<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title></title>
    <script src="../js/vue.js"></script>
</head>
<body>

<div id="root">
    <h1>{{name}}</h1>
    <div style="width: 100px;height: 100px;background-color: gray" @click="handleClick1">
        <div style="width: 20px;height: 20px;background-color: red" @click.stop="handleClick">

        </div>
    </div>
</div>
<script>
    Vue.config.productionTip = false;
    new Vue({
        el: "#root",
        data: {
            name: "初识Vue"
        },
        methods: {
            handleClick() {
                console.log("里面");
            },
            handleClick1() {
                console.log("外面");
            }
        }
    })
</script>

</body>
</html>
